﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Net;
using System.Net.Mail;

namespace Web1
{
    public partial class webUpload : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {

        }
        string filename = "";


        protected void Button1_Click(object sender, EventArgs e)
        {
            //string filename = @"\\192.168.1.58\UploadImg\images\browse.jpg";
            //System.IO.StreamReader SR = new System.IO.StreamReader(filename);
            //System.Net.Mail.MailMessage mail = new System.Net.Mail.MailMessage();


            //mail.Attachments.Add(new Attachment(SR.BaseStream, filename));

            //FileUpload1.FileContent

            //if (this.FileUpload1.HasFile)
            //{
            //    filename = this.FileUpload1.FileName;
            //    filename = System.IO.Path.Combine(this.Server.MapPath("Upload"), filename);
            //    this.FileUpload1.SaveAs(filename);


            //    WebClient WC = new WebClient();
            //    WC.DownloadFile(filename, "d:\\a.txt");

            //}      
        }
    }
}
